﻿using System;
using System.Collections.Generic;
using Infrastructure;
using Presentation;

namespace PresentationTest
{
    public class FakeView:IView

    {
        public string FromValue { get; set; }

        public string FromType { get; set; }

        public string ToType { get; set; }

        public string ToValue { get; set; }
        public string FileName { get; set; }
        public string Action { get; set; }

        public string ErrorMessage { get; set; }

        public event Action OnConvertClick;
        public event Action OnWriteLogToFile;
        public event Action OnTxtClick;
        public event Action OnHtmlClick;

        public void ConvertClick()
        {
            OnConvertClick();
        }

        public void WriteLogToFile()
        {
            OnWriteLogToFile();
        }

        public void HtmlLoggerClick()
        {
            OnHtmlClick();
        }

        public void TxtLoggerClick()
        {
            OnTxtClick();
        }


        public void ClearError()
        {
            ErrorMessage = "";
        }

        public ILog CreateTxtLogger()
        {
            return new TxtLogger();
        }

        public ILog CreateHtmlLogger()
        {
            return new HtmlLogger();
        }
    }
}
